package com.jc.service.userorder;

import com.jc.ds.base.service.BaseService;
import com.jc.ds.model.UserOrder;
import com.jc.service.chain.ChainRequestModel;
import com.jc.service.chain.ChainResult;

import java.math.BigDecimal;

public interface UserOrderService extends BaseService<UserOrder, Long> {
    Boolean isWithdrawalOfExcess(Long userId,BigDecimal bigAmount);
    
    /***
     * VRT转换交易函数
     * @param coin_name : 币名
     * @param amount 交易金额，游戏币
     * @param send_user_id_out 付款用户ID ，二号系统中的USERID
     * @param receive_user_id_out  收款用户ID  ， 二号系统中的USERID
     * @param remarks 备注
     * @param businessType 交易类型: 0 充值  1 提现
     * @param channel 渠道  h5游戏大厅  APP游戏 
     * @return
     */
    public ChainResult transfer(String coin_name, BigDecimal amount, Long send_user_id_out, Long receive_user_id_out, String remarks , int businessType,String channel,String channelOrderId);
    
    
    /***
     * 获取VRT账户余额
     * @param coin_name
     * @param address
     * @return
     */
    public ChainResult queryBalance(Long out_user_id,String coin_name);
    
    
    /***
     * 区块链回调处理
     * @param model
     * @return
     */
    public String transferCallBack(ChainRequestModel model);
}
